Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix CI (plus DX improvements) #2171

Closed
wants to merge 3 commits into from

Conversation

evenicoulddoit
Copy link

@evenicoulddoit evenicoulddoit commented Feb 7, 2025

What does this change

  • Uses extras_require to enforce consistent versioning of development / ci / testing requirements
  • Bumps mypy to latest version supported by Python 3.8
  • Updates CI to use tox to run mypy

What was wrong

  • The @overload decorator wasn't supported across the repo, due to the lack of support in the stub file generation
  • This prevented proper typing support for users who were trying to use the faker library
  • The development experience with Faker was made more difficult due to development and test requirements not being formalized centrally

How this fixes it

  • Addresses all of the above

Notes

Checklist

  • I have read the documentation about CONTRIBUTING
  • I have read the documentation about Coding style
  • I have run make lint

@evenicoulddoit evenicoulddoit changed the title Fix stub generation CI and development improvements Feb 7, 2025
@evenicoulddoit evenicoulddoit mentioned this pull request Feb 7, 2025
3 tasks
@evenicoulddoit
Copy link
Author

@fcurella MyPy is failing, but it's running against the latest version as CI is governed by the state of the master branch. Having copied the process via my fork, you can see that these changes will pass CI once fixed: https://github.com/evenicoulddoit/faker/actions/runs/13195989491/job/36837366554?pr=4

@evenicoulddoit evenicoulddoit changed the title CI and development improvements Fix CI (plus DX improvements) Feb 7, 2025
@fcurella
Copy link
Collaborator

fcurella commented Feb 7, 2025

Can you please undo all the DX changes, so we can review them in a separate PR?

@evenicoulddoit
Copy link
Author

@fcurella yes and no. The crucial fix here I think is bumping MyPy. This isn't fixed on the master branch. This PR applies strict limits across the board, and uses them. I can produce a PR which just bumps MyPy but it would also fail for the reasons above?

@fcurella
Copy link
Collaborator

Done in 9c8b132

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants